<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        * {
            margin: 0;
            padding: 0;
            list-style: none;
            text-decoration: none;
        }

        @keyframes tang {
            100% {
                background-size: 100%;
            }
        }

        .box {
            width: 150px;
            height: 30px;
            border: 1px solid#000;
            background: gray linear-gradient(#000 0 0) no-repeat 0/0%;
            animation: tang 2s infinite linear;
        }

        @keyframes han {
            100% {
                background-size: 100%;
            }
        }

        .son {
            width: 150px;
            height: 30px;
            background: linear-gradient(to right, red, skyblue) no-repeat 0/0%;
            border-radius: 30px;
            animation: han 2s infinite linear;
        }

        @keyframes tao {
            100% {
                background-size: 100%;
            }
        }

        .text {
            width: 150px;
            height: 30px;
            border: 1px solid#000;
            border-radius: 20px;
            background: repeating-linear-gradient(45deg, red 0 10px, orange 0 20px) 0/0% no-repeat, repeating-linear-gradient(45deg, #ddd 0 10px, #eee 0 20px) 0/100%;
            animation: tao 2s infinite linear;
        }

        @keyframes xiao {
            100% {
                background-size: 100%;
            }
        }

        .top {
            width: 150px;
            height: 20px;
            background:repeating-linear-gradient(90deg,#000 0 10px,#eee 0 20px) 0/0% no-repeat, repeating-linear-gradient(90deg, #ddd 0 10px, #eee 0 20px) 0/100%;;
            animation: xiao  2s infinite linear;
        }
    </style>
</head>

<body>
    <div class="box"></div>
    <div class="son"></div>
    <div class="text"></div>
    <div class="top"></div>
</body>

</html>